<extend name="Layout/ins_page" />
<block name="content">
	{:W('PageHeader/simple',array('name'=>'用户设置','search'=>'N'))}
	<form method='post' id="form_data" class="well form-horizontal">
		<input type="hidden" name="ajax" id="ajax" value="0">
		<div class="form-group">
			<label class="col-sm-2 control-label" for="list_rows">列表数量：</label>
			<div class="col-sm-10">
				<input class="form-control col-20" type="text" id="list_rows" name="list_rows" value="{$config.list_rows}" check="number" msg="必须是数字">
			</div>
		</div>
		<div class="form-group hidden">
			<label class="col-sm-2 control-label" for="list_rows">网页推送：</label>
			<div class="col-sm-10">
				<label class="col-6">
					<input name="push_web[]" class="ace push_web" type="checkbox" value="mail">
					<span class="lbl">邮件</span> </label>
				<label class="col-6">
					<input name="push_web[]" class="ace push_web" type="checkbox" value="flow">
					<span class="lbl">流程</span> </label>
				<label class="col-6">
					<input name="push_web[]" class="ace push_web" type="checkbox" value="info">
					<span class="lbl">信息</span> </label>
				<label class="col-6">
					<input name="push_web[]" class="ace push_web" type="checkbox" value="task">
					<span class="lbl">任务</span> </label>
				<label class="col-6">
					<input name="push_web[]" class="ace push_web" type="checkbox" value="message">
					<span class="lbl">消息</span> </label>
			</div>
		</div>
		<div class="form-group hidden">
			<label class="col-sm-2 control-label" for="list_rows">微信推送：</label>
			<div class="col-sm-10">
				<label class="col-6">
					<input name="push_wechat[]" class="ace push_wechat" type="checkbox" value="mail">
					<span class="lbl">邮件</span> </label>
				<label class="col-6">
					<input name="push_wechat[]" class="ace push_wechat" type="checkbox" value="flow">
					<span class="lbl">流程</span> </label>
				<label class="col-6">
					<input name="push_wechat[]" class="ace push_wechat" type="checkbox" value="info">
					<span class="lbl">信息</span> </label>
				<label class="col-6">
					<input name="push_wechat[]" class="ace push_wechat" type="checkbox" value="task">
					<span class="lbl">任务</span> </label>
				<label class="col-6">
					<input name="push_wechat[]" class="ace push_wechat" type="checkbox" value="message">
					<span class="lbl">消息</span> </label>
			</div>
		</div>
		<div class="form-group">
			<div class="col-sm-10 col-sm-offset-2">
				<a onclick="save()"  class="btn btn-sm btn-primary">保存</a>
			</div>
		</div>
	</form>
</block>
<block name="js">
	<script type="text/javascript">
		function save() {
			sendForm("form_data","{:U('save')}");
		};

		$(document).ready(function() {
			set_return_url();
			set_val('push_web',"{$config.push_web}");
			set_val('push_wechat',"{$config.push_wechat}");
		});
	</script>
</block>